import Vue from 'vue';
//2.新创建一个vue实例
let VUE = new Vue();
//保存配置组件多选
import {CESave,CEGain} from "@/api/baseManage/flBook/index";
//保存
export const SAVE_CHECK_BOXS=async function(obj){
    await CESave(obj).then(response=>{
            // alert('保存成功！')
            VUE.$notify({
                title: '',
                message: response.message,
                type: 'success'
              });
    }).catch(()=>{
            VUE.$notify.error({
                title: '',
                message: '保存失败！'
            });
    })
}
//获取  配置接口
export const GAIN_CHECK_BOXS=async function(userId,routerName){
    let newData={}
    await CEGain(userId,routerName).then(response=>{
        newData=response.data
        newData['ATE']='SUCCESS'
    }).catch(()=>{
        newData['ATE']='ERROR'
    })
    return newData
}